using System;
using System.ComponentModel.DataAnnotations;
using System.ComponentModel.DataAnnotations.Schema;
using Comteck.Domain.Entities;

namespace Comteck.Entities.Orders {
  /// <summary>
  /// 自提点
  /// </summary>

  [Table("SelfOrg")]
  public class SelfOrg : Entity<int> {
    /// <summary>
    /// 自提点id
    /// </summary>
    [Key]
    [Required, DatabaseGenerated(DatabaseGeneratedOption.Identity)]
    public override int Id { get; set; }

    /// <summary>
    /// 自提点名称
    /// </summary>
    [Required, MaxLength(500)]
    public string Name { get; set; }

    /// <summary>
    /// 自提点联系人
    /// </summary>
    public string Contacts { get; set; }

    /// <summary>
    /// 自提点电话
    /// </summary>
    public string Phone { get; set; }

    /// <summary>
    /// 自提点地址
    /// </summary>
    public string Address { get; set; }

    /// <summary>
    /// 收货人
    /// </summary>
    public string Recipient { get; set; }

    /// <summary>
    /// 收货人联系电话
    /// </summary>
    public string RecipientPhone { get; set; }

    /// <summary>
    /// 省份
    /// </summary>
    public string Province { get; set; }

    /// <summary>
    /// 城市
    /// </summary>
    public string City { get; set; }

    /// <summary>
    /// 区县
    /// </summary>
    public string District { get; set; }

    /// <summary>
    /// 街道
    /// </summary>
    public string Street { get; set; }

    /// <summary>
    /// 详细地址
    /// </summary>
    public string RecipientAddress { get; set; }

    /// <summary>
    /// 自提点标签id
    /// </summary>
    public int? TagId { get; set; }

    /// <summary>
    /// 创建时间
    /// </summary>
    [Required]
    public DateTime CreateTime { get; set; } = DateTime.Now;
  }
}
